Visual Basic (Declaration) | |
---|---|
Public Class EventHandlerForControl(Of TEventArgs As EventArgs) |
C# | |
---|---|
public class EventHandlerForControl<TEventArgs> where TEventArgs: EventArgs |
- TEventArgs
Library/Library.Test/TestDelegates.cs
C# | Copy Code |
---|---|
EventHandler<VerifiedReceiptEventArgs> handler; VerifiedReceiptEventArgs args = new VerifiedReceiptEventArgs(); _thread.Start(); _form.FormCreated.WaitOne(); try { handler = new EventHandlerForControl<VerifiedReceiptEventArgs>(_form, CloseTheForm); handler(null, args); } finally { _thread.Join(); } |
VB.NET | Copy Code |
---|---|
Dim handler As EventHandler(Of VerifiedReceiptEventArgs) Dim args As New VerifiedReceiptEventArgs() _thread.Start() _form.FormCreated.WaitOne() Try handler = New EventHandlerForControl(Of VerifiedReceiptEventArgs)(_form, CloseTheForm) handler(Nothing, args) Finally _thread.Join() End Try |
System.Object
CSharpTest.Net.Delegates.EventHandlerForControl<TEventArgs>
CSharpTest.Net.Delegates.EventHandlerForActiveControl<TEventArgs>
CSharpTest.Net.Delegates.ForcedEventHandlerForControl<TEventArgs>
Target Platforms: Windows XP, Windows Server 2003, Windows Vista, Windows Server 2008, Windows 7